<template>
  <div @click="divClick">
    <a @click.prevent.stop="fn" href="https://www.baidu.com">去百度</a>
  </div>
</template>

<script>
export default {

  data() {
    return {
      
    };
  },

  methods: {
    fn(){
      console.log('a被点了');
    },
    divClick(){
      console.log('div被点了');
    }
  },
};
</script>

<style>

</style>